Make gtk_window_set_focus call gtk_widget_grab_focus internally.
This means that set_focus can now end up putting the focus on
a child of the passed-in widget, and makes the focus-widget
property work for setting initial focus to (the child of) an
entry in a ui file.
{
g_return_if_fail (GTK_IS_WINDOW (window));
- gtk_root_set_focus (GTK_ROOT (window), focus);
+ if (focus)
+ gtk_widget_grab_focus (focus);
+ else
+ gtk_window_root_set_focus (GTK_ROOT (window), NULL);
}
static void